vcProgram

Program is an executable program that can be run by executor objects. Every executor, by default, has its own a built-in program.

See in: Overview

Module: vcExecutor

Parent: vcObject

Children -

Referenced by: vcRobotExecutor.Program, vcViewAnimation.Program

Properties

Learn how to use properties here. The properties are also inherited from the parent class.

NameTypeAccessDescription
MainRoutinevcRoutineRGets the main routine of the program.
NameStringRWGets or sets the name of the program.
PropertiesvcPropertyContainerRGets the properties of this program.
RoutinesvcObservableList[vcRoutine]RGets a list of all routines in the program other than the main routine.

Methods

Learn how to use methods here. The methods are also inherited from the parent class.

NameReturn TypeParametersDescription
createRoutinevcRoutineString nameCreates a new routine of a given name in the program.
See more
Parameters:
name (String): Routine's name.

Returns:
vcRoutine: the new routine.

Exceptions:
ValueError: When given routine name is empty or not unique.
findRoutinevcRoutineString nameFinds a routine matching a given name in the program.
See more
Parameters:
name (String): Routine's name.

Returns:
vcRoutine: The found routine. None if no routine was found.

Events

Learn how to use events here. The events are also inherited from the parent class.

NameParametersDescription
OnStatementAddedvcStatement statementTriggered when a statement is added to the program.

Parameters:
statement (vcStatement): The added statement.
OnStatementRemovingvcStatement statementTriggered when a statement is removed from the program.

Parameters:
statement (vcStatement): The removed statement.